package com.augn.controller;

import com.augn.entity.GoodsEvaluateFrom;
import com.augn.entity.GoodsEvaluateMain;
import com.augn.entity.Result;
import com.augn.service.IGoodsEvaluateFromService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.Iterator;
import java.util.List;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author augn
 * @since 2022-09-22
 */
@RestController
@RequestMapping("/goodsEvaluateFrom")
public class GoodsEvaluateFromController {

    @Autowired
    private IGoodsEvaluateFromService service;

    @PostMapping("/insertOne")
    public Result<?> insertOneGoodsEvaluateFrom(@RequestBody GoodsEvaluateFrom goodsEvaluateFrom){
        return service.insertOneGoodsEvaluateFrom(goodsEvaluateFrom);
    }

    @DeleteMapping("/deleteOne/{id}")
    public Result<?> deleteOneGoodsEvaluateFrom(@PathVariable Integer id){
        return service.deleteOneGoodsEvaluateFrom(id);
    }

    @GetMapping("/getPart/{id}")
    public Result<?> getPartGoodsEvaluateFrom(@PathVariable Integer id){
        return service.getPartGoodsEvaluateFrom(id);
    }
}
